********************************************************************************
*
**# Table A3.  Do DV Judges Make Different Decisions in DV Cases? Conditional 
*
********************************************************************************


use "${DATA}/data_DV.dta", clear

********************************************************************************
*
**##	Panel A
*
********************************************************************************

# d ; 

eststo clear 	;
local m = 1 	;

foreach y of varlist  incarcerated_case jail_time_case { ;

	eststo app_`m': 
	reghdfe `y' dv_judge if dv_case == 1 & guilty_case==1, $hdfe_opts ;
		
		estadd ysumm			;
		estadd local cntrl ""	;
		local m `++m'			;
					 
	eststo app_`m': 
	reghdfe `y' dv_judge $cntrls if dv_case == 1 & guilty_case==1, $hdfe_opts ;

		estadd ysumm			;
		estadd local cntrl "X"	;
		local m `++m'			;
} ;


esttab 	app_* using "${OUTPUT}/tabA3.rtf", replace ${tab_optns} 
		scalars("cntrl Controls""ymean Y Mean") 
		keep(dv_judge)
		title(Table A.3. Do DV Judges Make Different Decisions in DV Cases? Conditional -- Panel A) ;


# d cr 

********************************************************************************
*
**##	Panel B
*
********************************************************************************

# d ; 

eststo clear 	;
local m = 1 	;

foreach y of varlist  incarcerated_case jail_time_case { ;

	eststo app_`m': 
	reghdfe `y' dv_did dv_case dv_judge  if guilty_case==1,  $hdfe_opts ;
		
		estadd ysumm			;
		estadd local cntrl ""	;
		local m `++m'			;
					 
	eststo app_`m': 
	reghdfe `y' dv_did dv_case dv_judge $cntrls  if guilty_case==1, $hdfe_opts ;

		estadd ysumm			;
		estadd local cntrl "X"	;
		local m `++m'			;
} ;


esttab 	app_* using "${OUTPUT}/tabA3.rtf", append ${tab_optns} 
		scalars("cntrl Controls""ymean Y Mean") 
		keep(dv_did dv_case dv_judge)
		title(Table A.3. Panel B) ;
		
# d cr 


********************************************************************************
*   End of File
********************************************************************************
